﻿using Light.Framework.Contract;
using Light.Weixin.Model;
using System.Collections.Generic;

namespace Light.Weixin.Contract
{

    /// <summary>
    /// 消息模板访问组件
    /// </summary>
    public interface IWxMsgTplComponent : IComponent<WxMsgTpl>, IDataImport
    {
        /// <summary>
        /// 获取公众号下的所有消息模板
        /// </summary>
        /// <param name="originalId"></param>
        /// <returns></returns>
        IList<WxMsgTpl> GetMsgTpls(string originalId);

        /// <summary>
        /// 获取模板消息的模板
        /// </summary>
        /// <param name="app">公众号</param>
        /// <param name="name">内部的模板名称</param>
        /// <returns></returns>
        WxMsgTpl GetMsgTpl(WxApp app, string name);
    }
}
